
package com.work.test;

import java.io.Serializable;
import java.util.List;

import javax.xml.bind.annotation.*;

import org.apache.commons.lang3.builder.*;

@XmlAccessorType(XmlAccessType.FIELD)
@XmlType(name = "workspace", propOrder = {"collections"})
public class DsXmlWorkspace extends DsXmlBaseType implements Serializable {

	private static final long serialVersionUID = 3581064810333682238L;

	@XmlAttribute(name = "group", required = true)
	private String group;

	@XmlElement(required = false, name = "collection")
	List<DsXmlCollection> collections;

	public String getGroup()
	{
		return group;
	}

	public void setGroup(String group)
	{
		this.group = group;
	}

	public List<DsXmlCollection> getCollections()
	{
		return collections;
	}

	public void setCollections(List<DsXmlCollection> collections)
	{
		this.collections = collections;
	}

	public String toString()
	{
		return new ToStringBuilder(this, ToStringStyle.SHORT_PREFIX_STYLE)
				.append("title", getTitle()).append("operation", getOperation())
				.append("group", getGroup())
				.append("collections", collections == null ? "null" : collections.size())
				.toString();
	}

	public String toStringAll()
	{
		return ToStringBuilder.reflectionToString(this);
	}
}
